<!doctype html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<link href="css/mui.min.css" rel="stylesheet" />
	</head>
	<style>
		.mui-content{
			position: relative;
			float: left;
			width: 100%;
			height: 100%;
			background: #F8F8F8;
			bottom: 30px;
			display: inline-block;
		}
		.head{background: #FE6D60;
			width: 100%;
			height: 130px;
			position: relative;
			float: left;
			padding: 37px   15px;
			box-sizing: border-box;
		}
		.head>div:nth-child(1){
			position: relative;
			float: left;
			width: 55px;
			height: 100%;
		}
		
		.head>div:nth-child(1)>img{
				width: 55px;
				height: 55px;
				border-radius: 50%;
		}
		.head>div:nth-child(2){
			position: relative;
			float: left;
			width: calc(100% - 55px);
			padding-left: 10px;
			box-sizing: border-box;
			height: 100%;
		}
		.head>div:nth-child(2)>div:nth-child(1){
			width: calc(100% - 100px -  10px);
			height: 100%;
			position: relative;
			float: left;
		}
		
			.head>div:nth-child(2)>div:nth-child(1)>div:nth-child(1){
			width: 100%;
			height:15px;
			text-align: left;
			font-size:16px;
             font-weight:500;
             color:rgba(254,254,254,1); 
			 box-sizing: border-box;
			 position: relative;
			 margin-top: 7px;
			 float: left;
		}
		
			.head>div:nth-child(2)>div:nth-child(1)>div:nth-child(2){
			width: 100%;
			height:15px;
			text-align: left;
			position: relative;
			float: left;
			margin-top: 10px;
		}
		
		.head>div:nth-child(2)>div:nth-child(1)>div:nth-child(2)>img{
			position: relative;
			float: left;
			width: 64px;
			height: 15px;
		}
		
		.head>div:nth-child(2)>div:nth-child(1)>div:nth-child(2)>span{
			position: absolute;
			top: 0px;
			left: 20px;
			width: 38px;
			height:10px;
			font-size: 10px;
			line-height: 15px;
			color:rgba(254,254,254,1);
		}
		
		.head>div:nth-child(2)>div:nth-child(2){
			width: 100px;
			height: 100%;
			position: relative;
			float: left;
			padding-top: 15px;
			text-align: right;
		}
		.head>div:nth-child(2)>div:nth-child(2)>img{
			position: relative;
			float: right;
			width: 22px;
			height: 22px;
		}
		
		
		
		
		.xinxin{
			position: absolute;
            width: calc(100% - 30px);
			height: 80px;
			top: 107px;
			background: #FFFFFF;
			left: 15px;
			box-shadow:0px 3px 16px 0px rgba(215, 215, 215, 0.35);
            border-radius:8px;
			padding:  15px 15px  ;
			box-sizing: border-box;
		}
		
		.xinxin > div:nth-child(1){ 
			width: 80px;
			height: 100%;
			position: relative;
			float: left;
		}
			.xinxin > div:nth-child(1)>img{
				width: 80px;
				height: 50px;
			}
		
		
		.xinxins{
			position: relative;
			float: left;
			width: 200px;
			line-height: 48px;
		    width: calc(100% - 140px);
			box-sizing: border-box;
			font-size:11px;
			margin-left: 10px;
         
			font-family:PingFang SC;
			font-weight:500;
			color:rgba(153,153,153,1);
		} 
	.xuka{
		position: relative;
		float: right;
		width: 50px;
		 box-sizing: border-box;
		 color: red;
		 font-size: 15px;
		 text-align: center;
		 margin-top: 13px;
		 border-radius: 8px;
	}
		
		.jinbi{
			position: absolute;
			width: calc(100% - 30px);
			height: 80px;
			top:202px;
			background: #FFFFFF;
			left: 15px;
			box-shadow:0px 3px 16px 0px rgba(215, 215, 215, 0.35);
			border-radius:8px;
			padding:  15px 0px ;
			box-sizing: border-box;
			display: flex;
			padding-right: 15px;
			justify-content: space-around;
		}		
		.jinbi>div{
			position: relative;
			width: 25%;
			height: 100%;
			text-align: center;
			border-right: 1px solid rgba(235,235,235,1);
		}		
		.jinbi>div:last-child{
			border: none;
		}
		.jinbi>div>div{
			width:100%;
			height: 25px;
			position: relative;
			float: left;
			line-height: 25px;
			font-size:13px;
            font-weight:500;
            color:rgba(51,51,51,1);
		}
		
		.gongge{
			position: absolute;
			width: calc(100% - 30px);
			height: 163px;
			top:297px;
			background: #FFFFFF;
			left: 15px;
			box-shadow:0px 3px 16px 0px rgba(215, 215, 215, 0.35);
			border-radius:8px;
			box-sizing: border-box;
			padding-right: 15px;
		}	
		
		.gongge>div{
			position: relative;
			float: left;
			width: 20%;
			margin-left: 5%;
			height: 80px;
			text-align: center;
			padding-top: 18px;
		}
		.gongge>div>img{
			width: 25px;
			height: 25px;
			display: inline-block;
		}
		
		.gongge>div>div{
			position: relative;
			float: left;
			width: 100%;
			text-align: center;
			height: 25px;
			line-height: 25px;
			font-size:13px;
            font-weight:500;
            color:rgba(51,51,51,1);
		}
		
		
		.qita{
			position: absolute;
			width: calc(100% - 30px);
			top:475px;
			background: #FFFFFF;
			left: 15px;
			padding: 18px  15px;
			box-sizing: border-box;
		
		}
		.qita >div{
			position: relative;
			float: left;
			width: 100%;
			height:61px;
				padding-top: 23px;
				box-sizing: border-box;
			border-bottom: 1px solid rgba(235,235,235,1);
		}
		.qita >div:last-child{
			border-bottom:none;
		}
		.qitayi{
			position: relative;
			float: left;
			width: 25px;
			height: 100%;
		}
		
		.qitayi>img{
				width: 25px;
				height: 25px;
			}
		.qitaer{
			position: relative;
			float: left;
			width: 80px;
			height: 100%;
			padding-left: 6px;
			line-height: 25px;
			font-size:15px;
            font-weight:500;
            color:rgba(51,51,51,1);
		}
		
		
		.qitasan{
			position: relative;
			float: right;
			width: 30px;
			height: 100%;
			padding-left: 6px;
			line-height: 25px;
			font-size:13px;
            font-weight:500;
            color:rgba(255,92,91,1);
		}
		
		.qitasi{
			position: relative;
			float: right;
			width: 22px;
			height: 100%;
		}
		.qitasi>img{
			width: 22px;
			height: 22px;
			margin-top: 2px;
		}
		
		.recharge{
		   position: relative;
       		
		   background: red;
		   border-radius: 8px;
		   color: white!important;
		   box-sizing: border-box;
		   margin-top: 15px;
		}
		
	
	</style>
	<body>
		<div class="mui-content">
			<div class="head">
				<div  class="updatemodified" ><img id="touxiang" src="image/touxiang.png" /></div>
				<div>
					<div>
						<div id='yonghus'>用户:穆宇轩</div>
						<div><img id='hehuoren' src="image/vip.png" /><span id='hehuorens'>合伙人</span></div>
					</div>
					<div class="erwi">
						<img src="image/youjiantou.png" /><img src="image/minerweima.png" />
					</div>
				</div>
			</div>


			<!-- VIP卡 -->
			<div class="xinxin">
				<div><img src="image/vipdd.png" /></div>
				<div class="xinxins">一卡在手，无限观影</div>
				<div class="xuka">
					续卡
				</div>
			</div>




			<!-- 金币 -->
			<div class="jinbi">
				<div>
					<div id='myjinbi'>0</div>
					<div>金币</div>
				</div>
				<div>
					<div id="guanyingcishu">0</div>
					<div>观影次数</div>
				</div>
				<div>
					<div class="recharge">充值记录</div>
				</div>
			</div>




			<!-- 8宫格 -->
			<div class="gongge">
				<div class="hehr">
					<img src="image/hehuo1.png" />
					<div>合伙人</div>
				</div>
				<div class="fxiao">
					<img src="image/hehuo2.png" />
					<div>三级分销</div>
				</div>
				<div class="guankan">
					<img src="image/hehuo3.png" />
					<div>观看记录</div>
				</div>
				<div class="tuguang">
					<img src="image/hehuo4.png" />
					<div>分享推广</div>
				</div>
				<div class="chongzhigold" style="display: none;">
					<img src="image/hehuo5.png" />
					<div>充值</div>
				</div>
				<div class="tixian" style="display: none;">
					<img src="image/hehuo6.png" />
					<div>提现</div>
				</div>
				<div class="shouc">
					<img src="image/hehuo7.png" />
					<div>收藏</div>
				</div>
				<div class="draw">
					<img src="image/hehuo8.png" />
					<div>抽奖</div>
				</div>
			</div>


			<div class="qita">
				<div class="makefriends">
					<div class="qitayi"><img src="image/gong1.png" /></div>
					<div class="qitaer">交友广场</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				
				<div class="shangjiaruzhu">
					<div class="qitayi"><img src="image/shangjiaruzhu.png" /></div>
					<div class="qitaer">商家入驻</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				
				<div  class="orders">
					<div class="qitayi"><img src="image/gong2.png" /></div>
					<div class="qitaer">商城订单</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				<div  class="gwch">
					<div class="qitayi"><img src="image/gouwuc.png" /></div>
					<div class="qitaer">购物车</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				<div  class="address">
					<div class="qitayi"><img src="image/gong3.png" /></div>
					<div class="qitaer">收货地址</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				<div id="kefu">
					<div class="qitayi"><img src="image/gong4.png" /></div>
					<div class="qitaer">客服中心</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				<div class="updatepassword">
					<div class="qitayi"><img src="image/gong5.png" /></div>
					<div class="qitaer">修改密码</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
				<div class="xiaoxi">
					<div class="qitayi"><img src="image/gong6.png" /></div>
					<div class="qitaer">消息中心</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<div class="qitasan"></div>
				</div>
				<div class="tuichu">
					<div class="qitayi"><img src="image/gong7.png" /></div>
					<div class="qitaer">退出登录</div>
					<div class="qitasi"><img src="image/youjiantou.png" /></div>
					<!-- <div class="qitasan">(2)</div> -->
				</div>
			</div>
		</div>
	</body>

	<script src="js/mui.min.js"></script>
	<script src="js/jquery-3.1.1.min.js"></script>
	<script type="text/javascript">
	window.addEventListener("refresh", function (e) {
						location.reload();
					});
				
				
		mui.init();
		mui.plusReady(function() {
			var kehu = '';
			var height = window.screen.availHeight;
			$(".mui-content").css("height", height);
			var url = plus.storage.getItem('url');
			var user = plus.storage.getItem('user');
			// mui.alert(user);
			if(user){
				user = JSON.parse(user);
			}
			var Phone = '';
			mui.post(url+'/juyou/index/getmyinfo',{token:user.token},function(res){
				if(res.code==200){
					kehu = res.data.kehu;
					if(res.data.congzhi==1){
						$(".chongzhigold").show();
						$(".tixian").show();
					}
					$("#touxiang").attr('src',res.data.user.touxiang);
					var names=res.data.user.name?res.data.user.name:res.data.user.user;
					$("#yonghus").text('用户：'+names)
					if(res.data.hehuo<1){
						$("#hehuoren").hide();
						$("#hehuorens").text('游客');
					}
					$("#shenyu").text('剩余观影次数：'+res.data.user.guan_muner);
					$("#guanyingcishu").text(res.data.user.guan_muner)
					if(res.data.huiyuans>0){
						$(".xuka").text('续卡');
						$("#hehuorens").text('会员')
						if(res.data.huiyuan.hui_time=="永久有效"){
							$(".xinxins").text(res.data.huiyuan.hui_time)
						}else{
                           $(".xinxins").text(res.data.huiyuan.hui_time+' 到期')
						}
                   }else{
						$(".xuka").text('开卡');
						$("#wshy").text('开启会员，畅享天下!!')
					}
					$("#myjinbi").text(res.data.user.icons);
					if(res.data.message){
						$(".xiaoxi").children('div').eq(3).text("("+res.data.message+")")
					}
					Phone = res.data.kehu;
					
				}else{
					mui.toast(res.msg);
				}
			})
			
			//点击退出
			mui(".qita").on('tap','.tuichu',function(){
				mui.confirm('你确定要退出吗？','提示',['取消','确认'],function (e) {
					if(e.index==1){
						plus.storage.setItem('user','');
						plus.runtime.restart();
					}
				},'div')
			})
			
			
			
			//点击合伙人
			mui(".gongge").on("tap",".hehr",function(){
				$.post(url+'/juyou/hehuo/getren',{token:user.token},function(res){
					if(res.data.hehuo.length==0){
						mui.openWindow({
							url:"./sub5/partner.html",
							id:"./sub5/partner.html",
						})
					}else if(res.data.hehuo.status==1){
						mui.openWindow({
							url:"./sub5/subordinate.html",
							id:"./sub5/subordinate.html",
						})
					}else{
						mui.openWindow({
							url:"./sub5/partner.html",
							id:"./sub5/partner.html",
						})
					}
				})
				
				
				
			})
			
			
			
			
			
			
			
			
			//点击三级分销
			mui(".gongge").on("tap",".fxiao",function(){
				mui.openWindow({
					url:"./sub5/distribution.html",
					id:"./sub5/distribution.html",
				})
			})
			
			//点击观看纪录
			mui(".gongge").on("tap",".guankan",function(){
				mui.openWindow({
					url:"./sub5/watch.html",
					id:"./sub5/watch.html",
				})
			})
			
			//点击分享推广
			mui(".gongge").on("tap",".tuguang",function(){
				mui.openWindow({
					url:"./sub5/generalize.html",
					id:"./sub5/generalize.html",
				})
			})
			
			
					//点击充值  金币充值
			mui(".gongge").on("tap",".chongzhigold",function(){
				mui.openWindow({
					url:"./sub5/huchongzhigold.html",
					id:"./sub5/huchongzhigold.html",
				})
			})
			
			//点击续卡
				mui(".xinxin").on("tap",".xuka",function(){
				mui.openWindow({
					url:"./sub5/huchongzhi.html",
					id:"./sub5/huchongzhi.html",
				})
			})
			
				//点
				mui(".qita").on("tap",".updatepassword",function(){
				mui.openWindow({
					url:"forget_password.html",
					id:"forget_password.html",
				})
			})
			
			
			//点击提现
			mui(".gongge").on("tap",".tixian",function(){
				mui.openWindow({
					url:"./sub5/deposit.html",
					id:"./sub5/deposit.html",
				})
			})
			
			//点击收藏
			mui(".gongge").on("tap",".shouc",function(){
			
				mui.openWindow({
					url:"./sub5/collect.html",
					id:"./sub5/collect.html",
				})
			})
			
			//点击消息中心
			mui(".qita").on("tap",".xiaoxi",function(){
				mui.openWindow({
					url:"./sub5/center.html",
					id:"center.html",
				})
			})
			//点击交友广场
			mui(".qita").on("tap",".makefriends",function(){
				mui.openWindow({
					url:"./sub5/hujiaoyou.html",
					id:"./sub5/hujiaoyou.html",
				})
			})
			
					//点击
		mui(document).on("tap",".recharge",function(){
			mui.openWindow({
				url:"./sub5/paedrecord.html",
				id:"paedrecord.html",
			})
		})	
	
				//点击商城订单
			mui(".qita").on("tap",".orders",function(){
				mui.openWindow({
					url:"./sub5/huorders.html",
					id:"huorders.html",
				})
			})
			
			//点击商家入驻
			mui(".qita").on("tap",".shangjiaruzhu",function(){
				mui.post(url+'/juyou/mycommodity/getmycommodity',{token:user.token},function(res){
					if(res.code==200){
						if(res.data==2){
							mui.openWindow({
								url:"./sub5/myshangpin.html",
								id:"myshangpin.html",
							})
						}else if(res.data==1){
							mui.toast('平台正在审核,请耐心等待');
						}else{
							mui.toast('还没有成为商家请先去申请');
							setTimeout(function(){
								mui.openWindow({
									url:"./sub5/settled.html",
									id:"settled.html",
								})
							},1000)
						}
						
					}else{
						mui.toast(res.msg);
					}
				})
				
				
				
				// mui.openWindow({
				// 	url:"./sub5/myshangpin.html",
				// 	id:"./sub5/myshangpin.html",
				// })
				
				// mui.openWindow({
				// 	url:"./sub5/settled.html",
				// 	id:"./sub5/settled.html",
				// })
				// 
			})
			
			//点击购物车
			mui(".qita").on("tap",".gwch",function(){
				mui.openWindow({
					url:"./sub2/vehicle.html",
					id:"./sub2/vehicle.html",
				})
			})
			
			//点击收货地址
			mui(".qita").on("tap",".address",function(){
				mui.openWindow({
					url:"./sub5/myaddress.html",
					id:"./sub5/myaddress.html",
				})
			})
			
			
					//点击收货地址
			mui(".gongge").on("tap",".draw",function(){
				mui.openWindow({
					url:"./sub5/huluckdraw.html",
					id:"./sub5/huluckdraw.html",
				})
			})
			//点击二维码
			mui(".head").on("tap",".erwi",function(){
				mui.openWindow({
					url:"./sub5/generalize.html",
					id:"./sub5/generalize.html",
				})
			})
			
			//点击客服中心
			 document.getElementById("kefu").addEventListener('tap', function() { 
			        // var btnArray = ['拨打', '取消']; 
			        // // Phone = "025-88888888"; 
			        // mui.confirm('是否拨打 ' + Phone + ' ？', '提示', btnArray, function(e) { 
			        //     if (e.index == 0) { 
			        //         plus.device.dial(Phone, false); 
			        //     }  
			        // })
					window.open("mqqwpa://im/chat?chat_type=wpa&uin="+kehu+"&version=1&src_type=web&web_src=oicqzone.com")
			    })
		})
		
				//点击二维码
			mui(".head").on("tap",".updatemodified",function(){
				mui.openWindow({
					url:"modified.html",
					id:"modified.html",
				})
			})
			
		

		
	
	</script>
</html>
